<!doctype html>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script src="../assert_selection.js"></script>
<script>
    test(() => assert_selection(
        [
            '<div contenteditable>',
                '<ul><ul><li>^foo|</li></ul><li><br></li></ul>',
            '</div>',
        ].join(''),
        selection => {
            selection.document.execCommand('delete');
            selection.document.execCommand('delete');
        },
        [
            '<div contenteditable>',
                '<ul><li>|<br></li><li><br></li></ul>',
            '</div>',
        ].join('')),
        'Delete a list item to delete empty list');
</script>
